<template>
	<view>
		<view class="" style="padding: 20rpx;">
			<rich-text v-html="content"> </rich-text>
		</view>

	</view>
</template>

<script>
	import {
		config,
	} from '@/api/index.js'
	export default {
		components: {},
		computed: {

		},
		data() {
			return {
				title: '',
				content: '',

			}
		},
		onShow() {

		},
		onLoad(e) {
			this.title = e.title
			uni.setNavigationBarTitle({
				title: this.title
			})
			this.agreement()

		},

		methods: {
			agreement() {

				var url = config

				url().then(res => {
					if (this.title == '用户协议') {
						this.content = res.data.user_agreement
					}
					if (this.title == '隐私政策') {
						this.content = res.data.privacy_policy
					}
					if (this.title == '关于我们') {
						this.content = res.data.regards
					}
					if (this.title == '个人信息查询及使用授权书') {
						this.content = res.data.personage_info
					}
					if (this.title == '授权额度协议') {
						this.content = res.data.authorized_limit
					}
					if (this.title == '征信查询') {
						this.content = res.data.credit_inquiry
					}
				})
			},
		}
	}
</script>

<style lang="scss">
	page {
		background-color: #fff;
	}
</style>